package com.example.demo.design.GoF.observer.ring;

/**
 * //具体观察者类：老师事件监听器
 *
 * @author luowj12
 * @since 2021/5/8 15:27
 */
public class TeachEventListener implements BellEventListener {
    @Override
    public void heardBell(RingEvent e) {
        if (e.getSound()) {
            System.out.println("老师上课了...");
        } else {
            System.out.println("老师下课了...");
        }
    }
}
